package org.loda.demo;

import org.loda.model.Request;
import org.loda.model.Response;
import org.loda.service.Filter;
import org.loda.service.FilterChain;

/**
 * 
* @ClassName: EncodingFilter 
* @Description: 编码过滤器 
* @author minjun
*
 */
public class EncodingFilter implements Filter {

	@Override
	public void doFilter(Request request, Response response, FilterChain chain) {
		System.out.println("req:编码处理");
		request.setAttr("encoding", "utf-8");
		chain.doFilter(request, response);
		System.out.println("resp:编码处理");
	}

}
